DROP TABLE DBO.FPG_CALCULO_LOG
GO
CREATE TABLE DBO.FPG_CALCULO_LOG( CLL_COD INT IDENTITY
							, CLL_DATA DATETIME NOT NULL
							, CLL_USUARIO VARCHAR(50)
							, CLL_SENHA VARCHAR(50)
							, CLL_SESSAO VARCHAR(50)
							)
GO
ALTER TABLE DBO.FPG_CALCULO_LOG ADD CONSTRAINT PK_FPG_CALCULO_LOG PRIMARY KEY (CLL_COD)
GO
ALTER TABLE DBO.FPG_CALCULO_LOG ADD CLL_SENHA VARCHAR(50)
GO
ALTER TABLE DBO.FPG_CALCULO_LOG ADD CLL_SESSAO VARCHAR(50)
GO
DROP VIEW DBO.FPG_USUARIOS_VI
GO
CREATE VIEW DBO.FPG_USUARIOS_VI AS
	SELECT 
		USR_CODIGO
		, USR_LOGIN
		, USR_SENHA
		, USR_ADMINISTRADOR
		, @@SPID AS USR_CONEXAO
		, @@IDENTITY AS USR_IDENTITY
	FROM FR_USUARIO
GO

select * from fr_formulario
SELECT * FROM SYSOBJECTS WHERE XTYPE = 'U' AND NAME LIKE 'u%'
SELECT SES_USUARIO FROM FR_SESSAO_VI

Select * From   FPG_USUARIOS_VI

select convert( datetime, convert( sysname, getdate(), 103), 103 )


select * from FR_USUARIO where usr_login = 'neto'

4e3376064829bb8f853a3f0970f1de9b

select * from DBO.FPG_USUARIOS_VI

Select Top 1 @@SPID From FPG_PARAMETRO
select * from FPG_PARAMETRO



select * from DBO.FPG_CALCULO_LOG

Select
  FPG_CALCULO_LOG.CLL_COD,
  FPG_CALCULO_LOG.CLL_DATA,
  FPG_CALCULO_LOG.CLL_USUARIO,
  FPG_CALCULO_LOG.CLL_SENHA,
  FPG_CALCULO_LOG.CLL_SESSAO
From
  FPG_CALCULO_LOG
Where
  (FPG_CALCULO_LOG.CLL_USUARIO = 'neto' And
  FPG_CALCULO_LOG.CLL_SESSAO = 67)